package com.fjp.heartguard.ui.report.adapter

import android.widget.ImageView
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.fjp.heartguard.R
import com.fjp.heartguard.app.ext.dp
import com.fjp.heartguard.app.ext.setAdapterAnimation
import com.fjp.heartguard.app.util.SettingUtil
import com.fjp.heartguard.app.weight.pop.EditCertificatePop
import com.fjp.heartguard.app.weight.pop.TipPop
import com.fjp.heartguard.app.weight.seekbar.HTSeekBar
import com.fjp.heartguard.app.weight.seekbar.HTSeekBarLab
import com.lxj.xpopup.XPopup


class ReportDetailWarningAdapter(data: ArrayList<String>, var clickItem: (item: String) -> Unit) : BaseQuickAdapter<String, BaseViewHolder>(R.layout.item_report_detail_warning, data) {
    val colors = arrayListOf("#59D488","#D9D44B","#FF6600","#CB392B")
    init {
        setAdapterAnimation(SettingUtil.getListMode())
    }

    override fun convert(holder: BaseViewHolder, item: String) {
//        holder.setText(R.id.nameTv,)
//        holder.setText(R.id.nameTv,)
//        holder.setText(R.id.timeTv,"测评时间:"+)
//        holder.setText(R.id.sexValueTv,)
//        holder.setText(R.id.ageValueTv,)
//        holder.setText(R.id.addressValueTv,)
//        holder.setText(R.id.questionValueTv,)
        holder.itemView.setOnClickListener {
            clickItem("111")
        }

    }

    private fun showTipDialog(title:String,des:String) {
        XPopup.Builder(context).dismissOnTouchOutside(false).dismissOnBackPressed(false).isDestroyOnDismiss(true).autoOpenSoftInput(false).popupWidth(400.dp.toInt()).asCustom(TipPop(context,title,des)).show()
    }

}


